/*
* $Id: InfoItem.h 122 2010-07-22 17:05:50Z volok-aleksej@yandex.ru $
*
* Copyright 2010 by Volokitin Alexey
* All rights reserved
*
*/
#ifndef _INFO_ITEM_H_
#define _INFO_ITEM_H_

#include "../EditorDrawer/Controls/ButtonDraw.h"
#include "Structs.h"

class CItem : public InfoItem
{
	CSize s_size;
public:
	CSize GetSize();
	CSize InitSize(int cx);
public:
	CItem(const std::tstring& strContent, const std::tstring& strFontName, int nFontSize, bool bBold, bool bItalic);
};

class CInfoItem
{
	std::vector<CItem> m_aItems;
	bool m_bPaintButton;
	bool m_bSelected;
	CButtonDraw m_buttonMore;
	int m_nId;
protected:
	CSize m_size;
	CPoint m_point;
public:
	CInfoItem(int nId, IDrawer* pDrawer);
	~CInfoItem();
public:
	void AddInfoItem(InfoItem item);
	void ShowButton(bool bShow);
	bool IsSelect();
	void SetSelect(bool val);
	int GetId();
public:
	bool ProcessMouse(unsigned int nButton, CPoint pos, int param);
public:
	void SetSizeCx(int cx);
	void SetPosition(CPoint pos);
	CSize GetSize();
public:
	void Paint(CDC* dc);
};

#endif/*_INFO_ITEM_H_*/